package com.ipartek.desarrollo.beanHibernate;

// Generated 26-feb-2014 21:38:33 by Hibernate Tools 3.4.0.CR1

import static javax.persistence.GenerationType.IDENTITY;

import java.util.HashSet;
import java.util.Set;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToMany;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * Diccionariocampos generated by hbm2java
 */
@Entity
@Table(name = "diccionariocampos")
public class Diccionariocampos implements java.io.Serializable {

	private Integer campId;
	private Tipcamp tipcamp;
	private String campNom;
	private String campHtml;
	private Boolean pname;
	private Boolean psurname;
	private Boolean psrname2;
	private Boolean pmail;
	private Boolean ptelefono;
	private String campObv;
	private Set<Parametros> parametroses = new HashSet<Parametros>(0);

	public Diccionariocampos() {
	}

	public Diccionariocampos(Tipcamp tipcamp, String campNom, String campHtml,
			Boolean pname, Boolean psurname, Boolean psrname2, Boolean pmail,
			Boolean ptelefono, String campObv, Set<Parametros> parametroses) {
		this.tipcamp = tipcamp;
		this.campNom = campNom;
		this.campHtml = campHtml;
		this.pname = pname;
		this.psurname = psurname;
		this.psrname2 = psrname2;
		this.pmail = pmail;
		this.ptelefono = ptelefono;
		this.campObv = campObv;
		this.parametroses = parametroses;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "CampId", unique = true, nullable = false)
	public Integer getCampId() {
		return this.campId;
	}

	public void setCampId(Integer campId) {
		this.campId = campId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "TipCampId")
	public Tipcamp getTipcamp() {
		return this.tipcamp;
	}

	public void setTipcamp(Tipcamp tipcamp) {
		this.tipcamp = tipcamp;
	}

	@Column(name = "CampNom", length = 80)
	public String getCampNom() {
		return this.campNom;
	}

	public void setCampNom(String campNom) {
		this.campNom = campNom;
	}

	@Column(name = "CampHTML")
	public String getCampHtml() {
		return this.campHtml;
	}

	public void setCampHtml(String campHtml) {
		this.campHtml = campHtml;
	}

	@Column(name = "PName")
	public Boolean getPname() {
		return this.pname;
	}

	public void setPname(Boolean pname) {
		this.pname = pname;
	}

	@Column(name = "PSurname")
	public Boolean getPsurname() {
		return this.psurname;
	}

	public void setPsurname(Boolean psurname) {
		this.psurname = psurname;
	}

	@Column(name = "PSrname2")
	public Boolean getPsrname2() {
		return this.psrname2;
	}

	public void setPsrname2(Boolean psrname2) {
		this.psrname2 = psrname2;
	}

	@Column(name = "PMail")
	public Boolean getPmail() {
		return this.pmail;
	}

	public void setPmail(Boolean pmail) {
		this.pmail = pmail;
	}

	@Column(name = "PTelefono")
	public Boolean getPtelefono() {
		return this.ptelefono;
	}

	public void setPtelefono(Boolean ptelefono) {
		this.ptelefono = ptelefono;
	}

	@Column(name = "CampObv", length = 150)
	public String getCampObv() {
		return this.campObv;
	}

	public void setCampObv(String campObv) {
		this.campObv = campObv;
	}

	@ManyToMany(fetch = FetchType.LAZY, mappedBy = "diccionariocamposes")
	public Set<Parametros> getParametroses() {
		return this.parametroses;
	}

	public void setParametroses(Set<Parametros> parametroses) {
		this.parametroses = parametroses;
	}

}
